package parser;

import beans.CotizacionBean;
import beans.ItemCotizacionBean;

import com.thoughtworks.xstream.XStream;
import com.thoughtworks.xstream.converters.basic.DateConverter;

public class CotizacionXStream extends XStream 
{
	public CotizacionXStream() 
	{
		this.alias("Cotizacion", CotizacionBean.class);		
		this.alias("ItemCotizacion", ItemCotizacionBean.class);
		
		this.registerConverter(new DateConverter("ddMMyyyy", new String[]{"ddMMyyyy"}));
		this.registerConverter(new DateConverter("ddMMyyyy", new String[]{"ddMMyyyy","yyyy-MM-dd HH:mm:ss.S a","yyyy-MM-dd HH:mm:ssz", "yyyy-MM-dd HH:mm:ss z","yyyy-MM-dd HH:mm:ssa"}));
		this.registerConverter(new DateConverter("yyyy-MM-dd HH:mm:ss.S z", new String[]{"ddMMyyyy","yyyy-MM-dd HH:mm:ss.S a","yyyy-MM-dd HH:mm:ssz", "yyyy-MM-dd HH:mm:ss z","yyyy-MM-dd HH:mm:ssa"}));
	}
	
}
